Do not require libde265 at configure time - #93
Merged
Conversation
The add-on includes only libheif headers and has never called libde265 directly. Requiring it blocks configuration against a system libheif that already provides HEVC, whether built in or loaded as a plugin, which is how freedesktop-sdk and several distributions ship it. de265 stays in the include path and link line when it is found, so static libheif builds that pull in libde265 are unaffected.
|
| Filename | Overview |
|---|---|
| CMakeLists.txt | Makes libde265 optional without otherwise changing dependency ordering or the addon's link composition. |
Reviews (1): Last reviewed commit: "Do not require libde265 at configure tim..." | Re-trigger Greptile
garbear
approved these changes
Sep 3, 2026
kel-mo
added a commit
to kel-mo/tv.kodi.Kodi
that referenced
this pull request
Sep 6, 2026
Stop building libheif and libde265 for this addon. 26.08 ships libheif 1.23.1 and gets its HEVC backend from the codecs-extra extension, which carries the libheif-libde265 plugin; the runtime's build looks for it at lib/<triplet>/codecs-extra/lib/libheif. AVIF also improves, as the runtime's libheif links aom and svt-av1 next to dav1d. The addon required libde265 at configure time although it only ever includes libheif headers, which blocks configuring against a libheif that supplies HEVC itself. Move the pin to the Piers head, which carries the upstream fix (xbmc/imagedecoder.heif#93), so no local patch is needed. Everywhere libde265 is present, as in kodi's own depends builds, the link line is unchanged.
kel-mo
added a commit
to kel-mo/tv.kodi.Kodi
that referenced
this pull request
Sep 8, 2026
Stop building libheif and libde265 for this addon. 26.08 ships libheif 1.23.1 and gets its HEVC backend from the codecs-extra extension, which carries the libheif-libde265 plugin; the runtime's build looks for it at lib/<triplet>/codecs-extra/lib/libheif. AVIF also improves, as the runtime's libheif links aom and svt-av1 next to dav1d. The addon required libde265 at configure time although it only ever includes libheif headers, which blocks configuring against a libheif that supplies HEVC itself. Move the pin to the Piers head, which carries the upstream fix (xbmc/imagedecoder.heif#93), so no local patch is needed. Everywhere libde265 is present, as in kodi's own depends builds, the link line is unchanged.
kel-mo
added a commit
to kel-mo/tv.kodi.Kodi
that referenced
this pull request
Sep 9, 2026
Stop building libheif and libde265 for this addon. 26.08 ships libheif 1.23.1 and gets its HEVC backend from the codecs-extra extension, which carries the libheif-libde265 plugin; the runtime's build looks for it at lib/<triplet>/codecs-extra/lib/libheif. AVIF also improves, as the runtime's libheif links aom and svt-av1 next to dav1d. The addon required libde265 at configure time although it only ever includes libheif headers, which blocks configuring against a libheif that supplies HEVC itself. Move the pin to the Piers head, which carries the upstream fix (xbmc/imagedecoder.heif#93), so no local patch is needed. Everywhere libde265 is present, as in kodi's own depends builds, the link line is unchanged.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
src/includeskodi/addon-instance/ImageDecoder.h,libheif/heif_cxx.hand TinyEXIF — neverlibde265/de265.h.git log -S libde265 -- src/ lib/returns nothing, so theREQUIREDhas been vestigial for the life of the add-on.It does have a cost: it prevents configuring against a system libheif that supplies HEVC on its own. freedesktop-sdk 26.08 ships libheif 1.23.1 with plugin loading enabled and provides
libheif-libde265.sothrough thecodecs-extraextension; Debian splits the decoder out intolibheif-plugin-libde265the same way. In those environments libde265 need not be visible to this add-on at all.This only drops
REQUIRED.${de265_INCLUDE_DIRS}and${de265_LIBRARIES}are left in place, so wherever libde265 is found — including Kodi's own depends builds, whereFindHEIF.cmakeresolves a static libheif and cannot pick up transitive libraries from pkg-config — the include path and link line are byte-for-byte unchanged.Testing: built in the Flathub
tv.kodi.Kodimanifest against freedesktop-sdk 26.08 with the bundled libheif and libde265 modules removed. The resultingimagedecoder.heif.solists onlylibheif.so.1(plus tinyxml2 and libc) inDT_NEEDED. Four HEIC images display correctly in Kodi 22: 4032×3024 and 4000×3000 grid-tiled files of 48 HEVC tiles each, 8-bit 4:2:0, profiles Main and Main Still Picture, exercising tile assembly, embedded thumbnails, EXIF andirotrotation.